#ifndef STATICOBJECT_H
#define STATICOBJECT_H

#include "ngl/Vector.h"

/// @file StaticObject.h
/// @brief represents a static object in the system
/// @author Perseedoss Rajiv
/// @version 1.0
/// @date 29.03.11
/// Revision History :
/// Initial Version 29.03.11
/// @class StaticObject
/// @brief the base of all actors in the flocking system, such as obstacles, boids,
/// predators, it represent a static object with no velocity or movement

class StaticObject
{
public:
    /// @brief ctor
    /// @param[in] _pos the cartesian position of the object
    /// @param[in] _boundingSphere the radius of the bounding sphere
    /// @param[in] _influenceSphere the radius of the influence sphere
    StaticObject
            (
                const ngl::Vector _pos,
                const float _boundingSphere=1,
                const float _influenceSphere=1
            );

    /// @brief dtor
    inline ~StaticObject() { std::cout << "Static Object deleted" << std::endl; }

    /// @brief returns the position of the object
    inline ngl::Vector getPosition() const { return m_position; }

    /// @brief set the position of the object
    /// @param[in] _pos the cartesian position
    inline void setPosition(const ngl::Vector _pos) { m_position = _pos; }

    /// @brief returns the radius of the bounding sphere of the object
    inline float getBoundingRadius() const { return m_boundingRadius; }

    /// @brief set the radius of the bounding sphere of the object
    /// @param[in] _radius the bounding sphere radius
    inline void setBoundingRadius(const float _radius) { m_boundingRadius = _radius; }

    /// @brief returns the radius of the influence sphere of the object
    inline float getInfluenceRadius() const { return m_influenceRadius; }

    /// @brief set the radius of the influence sphere of the object
    /// @param[in] _radius the influence sphere radius
    inline void setInfluenceRadius(const float _radius) { m_influenceRadius = _radius; }

    /// @brief returns the state of the draw bounding sphere flag
    inline bool getDrawBoundingSphere() const { return m_drawBoundingSphere; }

    /// @brief set the flag to control drawing of the bounding sphere of the object
    /// @param[in] _state the boolean state
    inline void setDrawBoundingSphere(const bool _state) { m_drawBoundingSphere = _state; }


protected:
    /// @brief the position of the object
    ngl::Vector m_position;

    /// @brief the bounding sphere radius of the object
    float m_boundingRadius;

    /// @brief the influence sphere radius of the object
    float m_influenceRadius;

    /// @brief flag to toggle drawing of the bounding sphere of the object
    bool m_drawBoundingSphere;
};

#endif // STATICOBJECT_H
